# -*- coding: UTF-8 -*-
"""SimGNN runner."""

from utils import tab_printer
from simgnn import SimGNNTrainer
from param_parser import parameter_parser


def main():
    """
    Parsing command line parameters, reading data.
    Fitting and scoring a SimGNN model.
    """
    args = parameter_parser()  # 参数解析
    tab_printer(args)  # 可视化命令行参数
    trainer = SimGNNTrainer(args)  # 模型训练类接收命令行参数
    if args.load_path:
        trainer.load()
    else:
        trainer.fit()  # 模型训练
    trainer.score()
    if args.save_path:
        trainer.save()


if __name__ == "__main__":
    main()
